<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>vue数据绑定</title>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
  </head>
  <body>
    <div id="app">
      <div v-text="msg"></div>
      <div v-html="msg2"></div>
      <div v-pre>{{msg}}</div>
    </div>

    <script>
      var vm = new Vue({
        el: '#app',
        data: {
          msg: 'Hello Vue',
          msg2: '<h3>Hello HTML</h3>',
        },
      });
    </script>
  </body>
</html>
